{% extends "base.html" %}
{% block title %}登录{% endblock %}
{% block page_content %}

    <div id="mainbody">
         <div class="container">
            <h1 class="page-header">登录</h1>
             <div class="col-md-6">
             <form role="form" class="LoginForm" action="{% url 'weblogin' %}" method="post" role="form">
                  {% csrf_token %}
                <fieldset>
                    {% for field in form.visible_fields %}
        <div class="form-group{% if field.errors %} has-error{% endif %}">
          <label for="{{ field.label }}">{{ field.label }}</label>
          {{ field }}
          {% if field.help_text %}
            <span class="help-block">{{ field.help_text|safe }}</span>
          {% endif %}
          {% for error in field.errors %}
            <label class="control-label">{{ error }}</label>
          {% endfor %}
        </div>
      {% endfor %}

                </fieldset>

        <div class="form-group">
            <div  class="form-group-left">
              <button type="submit" class="btn btn-large btn-primary">提交</button>

              </div>
          </div>
             </form>

            </div>

         </div>
    </div>
    <!--主体内容结束-->

{% endblock %}